<template>
  <div className="title-section" @click="titleClick">
    <img src="../../../assets/img/secondTitle.png" alt="" class="title-img">
    <h3 className="YouSheBiaoTiHei-2">
      <span className="active">{{ title }}</span>
    </h3>
  </div>
</template>

<script setup>
defineProps({
  title: {
    type: String,
    default: '服务概况'
  },
});
const emit = defineEmits(['titleClick'])
const titleClick = ()=> {
    emit('titleClick')
}
</script>

<style scoped>
.title-img {
  position: absolute;
  left: 0;
  top: 14px;
  z-index: 0;
}

.YouSheBiaoTiHei-2 {
  font-size: 20px;
  font-weight: bold;
}
h3 {
  position: relative;
  font-size: 18px;
  font-weight: 400;
  line-height: 40px;
  text-align: left;
  padding-left: 42px;
  box-sizing: border-box;
  background-size: contain;
  color: #82858a;
  z-index: 9
}

h3 span {
  display: inline-block;
  margin-right: 10px;
  line-height: 30px
}

h3 span:last-child {
  margin-right: 0
}

h3 .active {
  color: #fff
}
</style>
